package com.ww.springstudy.config.condition;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

/**
 * 描述：
 *
 * @author 🧑 ‍wanwei
 * @since 2023-03-31 09:49
 */
@ConditionalOnClass(ConditionConfig4.class)
@Component
public class ConditionConfig3 {

    @Autowired
    private ConditionConfig2 conditionConfig2;

    @PostConstruct
    private void init() {
        System.out.println(conditionConfig2);
    }
}
